package com.ohuang.imghide

import android.os.Bundle
import android.view.LayoutInflater
import androidx.appcompat.app.AppCompatActivity
import java.lang.reflect.InvocationTargetException
import java.lang.reflect.Method

abstract class ViewBindActivity<T : androidx.viewbinding.ViewBinding> : AppCompatActivity() {

    var binding: T? = null
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        binding = getViewBinding()
        setContentView(binding!!.root)
        initView()
    }

    abstract fun getViewBinding(): T


    abstract fun initView()
}